﻿<ResourceDictionary
	xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
	xmlns:clr="clr-namespace:System;assembly=mscorlib"	
	xmlns:clr2="clr-namespace:System.Collections;assembly=mscorlib"
	xmlns:local="clr-namespace:Deepforest.WPF.Controls"
	xmlns:data="clr-namespace:Deepforest.WPF.Controls.Data"
	xmlns:converters="clr-namespace:Deepforest.WPF.Controls.Converters"
	xmlns:d="http://schemas.microsoft.com/expression/blend/2006"
	xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
	mc:Ignorable="d">

    <local:PropertyTemplateSelector x:Key="propertyTemplateSelector" />

    <SolidColorBrush x:Key="coldWaterBrush" Color="#FF5FA7FD"/>
    <SolidColorBrush x:Key="hotWaterBrush" Color="#FFFF7F4F"/>

    <LinearGradientBrush x:Key="TabBackgroundBrush" EndPoint="0.5,1" StartPoint="0.5,0">
        <GradientStop Color="#FF040404" Offset="0"/>
        <GradientStop Color="#FF000000" Offset="1"/>
        <GradientStop Color="#FF393939" Offset="0.518"/>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="TabBorderBrush" EndPoint="0.5,1" StartPoint="0.5,0">
        <GradientStop Color="#FF000000" Offset="0"/>
        <GradientStop Color="#FF000000" Offset="0.995"/>
        <GradientStop Color="#FF3F3F3F" Offset="0.504"/>
    </LinearGradientBrush>

    <SolidColorBrush x:Key="TabForegroundBrush" Color="#FF000000"/>

    <!-- Property Grid Brushes -->

    <SolidColorBrush x:Key="ExpanderBackgroundBrush" Color="#FF595959"/>

    <SolidColorBrush x:Key="ExpanderBorderBrush" Color="#FF333333"/>

    <SolidColorBrush x:Key="PropertiesForegroundBrush" Color="#FFFFFFFF"/>

    <!-- NormalBrush is used as the Background for SimpleButton, SimpleRepeatButton -->
    <LinearGradientBrush x:Key="NormalBrush" EndPoint="0,1" StartPoint="0,0">
        <GradientStop Color="#EEE" Offset="0.0"/>
        <GradientStop Color="#CCC" Offset="1.0"/>
    </LinearGradientBrush>
    <LinearGradientBrush x:Key="NormalBorderBrush" EndPoint="0,1" StartPoint="0,0">
        <GradientStop Color="#CCC" Offset="0.0"/>
        <GradientStop Color="#444" Offset="1.0"/>
    </LinearGradientBrush>

    <!-- LightBrush is used for content areas such as Menu, Tab Control background -->
    <LinearGradientBrush x:Key="LightBrush" EndPoint="0,1" StartPoint="0,0">
        <GradientStop Color="#FFF" Offset="0.0"/>
        <GradientStop Color="#EEE" Offset="1.0"/>
    </LinearGradientBrush>

    <!-- MouseOverBrush is used for MouseOver in Button, Radio Button, CheckBox -->
    <LinearGradientBrush x:Key="MouseOverBrush" EndPoint="0,1" StartPoint="0,0">
        <GradientStop Color="#FFF" Offset="0.0"/>
        <GradientStop Color="#AAA" Offset="1.0"/>
    </LinearGradientBrush>

    <!-- PressedBrush is used for Pressed in Button, Radio Button, CheckBox -->
    <LinearGradientBrush x:Key="PressedBrush" EndPoint="0,1" StartPoint="0,0">
        <GradientStop Color="#BBB" Offset="0.0"/>
        <GradientStop Color="#EEE" Offset="0.1"/>
        <GradientStop Color="#EEE" Offset="0.9"/>
        <GradientStop Color="#FFF" Offset="1.0"/>
    </LinearGradientBrush>
    <LinearGradientBrush x:Key="PressedBorderBrush" EndPoint="0,1" StartPoint="0,0">
        <GradientStop Color="#444" Offset="0.0"/>
        <GradientStop Color="#888" Offset="1.0"/>
    </LinearGradientBrush>

    <!-- SelectedBackgroundBrush is used for the Selected item in ListBoxItem, ComboBoxItem-->
    <SolidColorBrush x:Key="SelectedBackgroundBrush" Color="#DDD"/>

    <!-- Disabled Brushes are used for the Disabled look of each control -->
    <SolidColorBrush x:Key="DisabledForegroundBrush" Color="#888"/>
    <SolidColorBrush x:Key="DisabledBackgroundBrush" Color="#EEE"/>
    <SolidColorBrush x:Key="DisabledBorderBrush" Color="#AAA"/>

    <!-- Used for background of ScrollViewer, TreeView, ListBox, Expander, TextBox, Tab Control -->
    <SolidColorBrush x:Key="WindowBackgroundBrush" Color="#FFF"/>

    <!-- DefaultedBorderBrush is used to show KeyBoardFocus -->
    <LinearGradientBrush x:Key="DefaultedBorderBrush" EndPoint="0,1" StartPoint="0,0">
        <GradientStop Color="#777" Offset="0.0"/>
        <GradientStop Color="#000" Offset="1.0"/>
    </LinearGradientBrush>

    <SolidColorBrush x:Key="SolidBorderBrush" Color="#888"/>
    <SolidColorBrush x:Key="LightBorderBrush" Color="#AAA"/>
    <SolidColorBrush x:Key="LightColorBrush" Color="#DDD"/>

    <!-- Used for Checkmark, Radio button, TreeViewItem, Expander ToggleButton glyphs -->
    <SolidColorBrush x:Key="GlyphBrush" Color="#444"/>

    <LinearGradientBrush x:Key="ContentBorderBrush" EndPoint="0.5,1" StartPoint="0.5,0">
        <GradientStop Color="#FF272727" Offset="0"/>
        <GradientStop Color="#FF525252" Offset="0.995"/>
        <GradientStop Color="#FF323232" Offset="0.465"/>
    </LinearGradientBrush>

    <SolidColorBrush x:Key="DefaultForegroundBrush" Color="#FFCCCCCC"/>

    <LinearGradientBrush x:Key="ContentBackgroundBrush" EndPoint="0.5,1.0" StartPoint="0.5,0">
        <GradientStop Color="#FF232323" Offset="0"/>
        <GradientStop Color="#FF000000" Offset="1"/>
        <GradientStop Color="#FF393939" Offset="0.48"/>
    </LinearGradientBrush>

    <!--******************************************************************-->
    <!--********************* Dark-Blue Brushes *********************-->
    <!--******************************************************************-->

    <!--****************-->
    <!-- Default Colors -->
    <!--****************-->
    <!-- Background -->
    <SolidColorBrush  x:Key="DefaultMainBackgroundBrush" Color="#FF0F1622"/>
    <SolidColorBrush  x:Key="DefaultControlBrush" Color="#FF1F2A43"/>
    <SolidColorBrush  x:Key="DefaultControlBrightBrush" Color="#FF293D66"/>
    <!-- Foreground -->
    <SolidColorBrush x:Key="DefaultControlForegroundBrush" Color="#FFBFD1FF"/>
    <SolidColorBrush x:Key="DefaultPathForegroundBrush" Color="#FF88A0C1"/>
    <!-- Border -->
    <SolidColorBrush x:Key="DefaultControlBorderBrush" Color="#FF265184"/>
    <!-- Glossy -->
    <LinearGradientBrush x:Key="DefaultControlGlossyBrush" EndPoint="0.545,2.847" StartPoint="0.545,-0.639">
        <GradientStop Color="#FFCBCEFF" Offset="0.115"/>
        <GradientStop Color="#FF2A3756" Offset="0.476"/>
    </LinearGradientBrush>

    <!--********************-->
    <!-- Highlighted Colors -->
    <!--********************-->

    <!-- Background -->
    <LinearGradientBrush x:Key="HighlightedControlBrush" EndPoint="0.505,2.832" StartPoint="0.505,-0.654">
        <GradientStop Color="#FF2C3B5C" Offset="0"/>
        <GradientStop Color="#FF1F2A43" Offset="1"/>
    </LinearGradientBrush>
    <!-- Border -->
    <SolidColorBrush x:Key="HighlightedControlBorderBrush" Color="#FF5F6CC8"/>
    <!-- Glossy -->
    <LinearGradientBrush x:Key="HighlightedControlGlossyBrush" EndPoint="0.545,2.847" StartPoint="0.545,-0.639">
        <GradientStop Color="#FFCBCEFF" Offset="0.052"/>
        <GradientStop Color="#FF2C3B5C" Offset="0.457"/>
    </LinearGradientBrush>

    <!-- ListViewItem Colors -->
    <SolidColorBrush x:Key="HighlightedListViewItemBrush" Color="#FF2462A3"/>
    <SolidColorBrush x:Key="HighlightedLessListViewItemBrush" Color="#FF8590DA"/>
    <SolidColorBrush x:Key="ListViewBrightBackground" Color="#FF111A2A"/>
    <SolidColorBrush x:Key="ListViewDarkBackground" Color="#FF0D101A"/>

    <LinearGradientBrush x:Key="VerticalScrollBarBrush" EndPoint="1,0.5" StartPoint="0,0.5">
        <GradientStop Color="#FF0F1522" Offset="0"/>
        <GradientStop Color="#FF182438" Offset="1"/>
        <GradientStop Color="#FF1A273D" Offset="0.267"/>
        <GradientStop Color="#FF1D2B44" Offset="0.521"/>
        <GradientStop Color="#FF1C2940" Offset="0.744"/>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="HorizentalScrollBarBrush" EndPoint="0.506,0.994" StartPoint="0.506,0.006">
        <GradientStop Color="#FF0F1522" Offset="0"/>
        <GradientStop Color="#FF182438" Offset="1"/>
        <GradientStop Color="#FF1A273D" Offset="0.267"/>
        <GradientStop Color="#FF1D2B44" Offset="0.521"/>
        <GradientStop Color="#FF1C2940" Offset="0.744"/>
    </LinearGradientBrush>

    <!--****************-->
    <!-- Focused Colors -->
    <!--****************-->

    <!-- Border -->
    <SolidColorBrush x:Key="FocusedControlBorderBrush" Color="#FF7482E5" />
    <!-- Glossy -->
    <LinearGradientBrush x:Key="FocusedControlGlossyBrush" EndPoint="0.545,2.847" StartPoint="0.545,-0.639">
        <GradientStop Color="#FFCBCEFF" Offset="0.115"/>
        <GradientStop Color="#FF18183F" Offset="0.731"/>
    </LinearGradientBrush>

    <!--****************-->
    <!-- Checked Colors -->
    <!--****************-->

    <!-- Background -->
    <LinearGradientBrush x:Key="CheckedControlBrush" EndPoint="0.505,2.832" StartPoint="0.505,-0.654">
        <GradientStop Color="#FF3D5CA3" Offset="0"/>
        <GradientStop Color="#FF3D5CA3" Offset="1"/>
    </LinearGradientBrush>
    <!-- Glossy -->
    <LinearGradientBrush x:Key="CheckedControlGlossyBrush" EndPoint="0.545,2.847" StartPoint="0.545,-0.639">
        <GradientStop Color="#FFCBCEFF" Offset="0.173"/>
        <GradientStop Color="#FF6E79C5" Offset="1"/>
        <GradientStop Color="#FF3F499F" Offset="0.51"/>
    </LinearGradientBrush>

    <!--****************-->
    <!-- Pressed Colors -->
    <!--****************-->

    <!-- Background -->
    <LinearGradientBrush x:Key="PressedControlBrush" EndPoint="0.518,0.948" StartPoint="0.514,0.104">
        <GradientStop Color="#FF14213F" Offset="0"/>
        <GradientStop Color="#FF36476E" Offset="1"/>
        <GradientStop Color="#FF0D0F1C" Offset="0.423"/>
    </LinearGradientBrush>
    <!-- Glossy -->
    <LinearGradientBrush x:Key="PressedControlGlossyBrush" EndPoint="0.545,2.847" StartPoint="0.545,-0.639">
        <GradientStop Color="#FFCBCEFF" Offset="0"/>
        <GradientStop Color="#FF1A1E3B" Offset="0.212"/>
    </LinearGradientBrush>

    <!--*****************-->
    <!-- Disabled Colors -->
    <!--*****************-->

    <!-- Background -->
    <Brush x:Key="DisabledControlBrush">#FF414655</Brush>
    <!-- Foreground -->
    <SolidColorBrush x:Key="DisabledControlForegroundBrush" Color="#FFB4B4B4"/>
    <!-- Border -->
    <SolidColorBrush x:Key="DisabledControlBorderBrush" Color="#FF646464"/>
    <!-- Glossy -->
    <LinearGradientBrush x:Key="DisabledControlGlossyBrush" EndPoint="0.545,2.847" StartPoint="0.545,-0.639">
        <GradientStop Color="#FFCBCEFF" Offset="0.115"/>
        <GradientStop Color="#FF1E1E1E" Offset="0.567"/>
    </LinearGradientBrush>

    <!--************************-->
    <!-- Settings Screen Colors -->
    <!--************************-->

    <SolidColorBrush x:Key="SettingScreenBackgroung" Color="#FF576786"/>
    <SolidColorBrush x:Key="SettingScreenBorderBrush" Color="#FF555788"/>
    <SolidColorBrush x:Key="SettingPageBorderBrush" Color="Black"/>

    <!--************************-->
    <!-- ComboBox Colors -->
    <!--************************-->
    <SolidColorBrush x:Key="ComboBoxEditBoxBackgroung" Color="#FF576786"/>

    <!--************************-->
    <!-- MainShell Background Colors -->
    <!--************************-->
    <SolidColorBrush x:Key="MainShellBackground" Color="#FF0F0817"/>

    <!--************************-->
    <!-- Dialog Title Colors -->
    <!--************************-->
    <SolidColorBrush x:Key="DialogTitleBrush" Color="#FF1C2A41"/>

    <!--************************-->
    <!-- Cine Tab Control Background Colors -->
    <!--************************-->
    <SolidColorBrush x:Key="CineTabControlStroke" Color="Black"/>

    <!--************************-->
    <!-- Patient Details View Colors -->
    <!--************************-->
    <SolidColorBrush x:Key="PatientDetailsView" Color="#FF90ABB5"/>

    <!--************************-->
    <!-- Patient Registration Right Side Colors -->
    <!--************************-->

    <!--Right Side Colors-->
    <SolidColorBrush x:Key="PatientRegistrationGrid" Color="#FF202D45"/>

    <!--Patient Details Background Colors-->
    <SolidColorBrush x:Key="PatientDetailsBackground" Color="#FF293C5B"/>

    <!--Bottom Grid Background Colors-->
    <SolidColorBrush x:Key="BottomGridBackground" Color="#FF1B2436"/>

    <SolidColorBrush x:Key="YellowBorder" Color="#FFFFC400"/>

    <!--************************-->
    <!-- Yellow Foreground Colors -->
    <!--************************-->
    <SolidColorBrush x:Key="YellowForeground" Color="#FFFFCF00"/>

    <!--************************-->
    <!-- Mirror State Colors -->
    <!--************************-->
    <SolidColorBrush x:Key="MirrorStateBorderBrush" Color="#FFFFCF00"/>
    <SolidColorBrush x:Key="MirrorStateBackground" Color="Black"/>
    <SolidColorBrush x:Key="MirrorStateForeground" Color="White"/>

    <!--************************-->
    <!-- Grid View Colors -->
    <!--************************-->
    <SolidColorBrush x:Key="GridViewBackground" Color="#FF1F2A43"/>



    <!--************************-->
    <!-- ListBox  Colors   -->
    <!--************************-->
    <SolidColorBrush x:Key="ListBoxBackground" Color="#FF03080D"/>
    <SolidColorBrush x:Key="HighlightedListBoxItemBrush" Color="#FF3399FF"/>

    <!--************************-->
    <!-- Image Info Foreground  Colors   -->
    <!--************************-->
    <SolidColorBrush x:Key="ImageInfoForegroundDark" Color="#FFC3C3C3"/>
    <SolidColorBrush x:Key="ImageInfoForegroundWhite" Color="White"/>

    <!--***********************-->
    <!-- Database View Colors  -->
    <!--***********************-->

    <SolidColorBrush x:Key="DatabaseBackground" Color="#FF0F1622"/>
    <SolidColorBrush x:Key="DatabaseImagesBackground" Color="Black"/>
    <SolidColorBrush x:Key="DatabaseLightBorderBackground" Color="#293C5B"/>
    <SolidColorBrush x:Key="DatabaseDarkBorderBackground" Color="#1B293F"/>

    <!--***********************-->
    <!-- MessageBox Out Background Colors  -->
    <!--***********************-->
    <LinearGradientBrush x:Key="MessageBoxTitle" EndPoint="1,0.5" StartPoint="0,0.5">
        <GradientStop Color="#FFD5DFE9" Offset="0"/>
        <GradientStop Color="#FFD5DFE9" Offset="0.431"/>
        <GradientStop Color="#FFA7BCDB" Offset="0.825"/>
        <GradientStop Color="#FFF5FCFF" Offset="1"/>
    </LinearGradientBrush>

    <SolidColorBrush x:Key="MessageBoxTitleText" Color="#FF161A25"/>


    <!--*********************************-->
    <!-- ListView Background Tail Brush  -->
    <!--*********************************-->



    <!--************************-->
    <!-- ProgressBar  Colors   -->
    <!--************************-->

    <SolidColorBrush x:Key="ProgressBarBackground" Color="Black"/>
    <LinearGradientBrush x:Key="ProgressBarFill" EndPoint="0.498,0.061" StartPoint="0.498,1.054">
        <GradientStop Color="#FF184CA4" Offset="0"/>
        <GradientStop Color="#FF3398FE" Offset="1"/>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ProgressbarBrush" EndPoint="1,0.5" StartPoint="0,0.5">
        <GradientStop Color="#FF50837A" Offset="0"/>
        <GradientStop Color="#FF50837A" Offset="1"/>
        <GradientStop Color="#FFFFFFFF" Offset="0.533"/>
    </LinearGradientBrush>

    <!--*********************************-->
    <!--          Button Brush          -->
    <!--*********************************-->

    <!-- Content Brush -->
    <SolidColorBrush x:Key="ButtonContentBrush" Color="#FFBFD1FF"/>
    <SolidColorBrush x:Key="ButtonContentCheckedBrush" Color="#FFF0F5FF"/>
    <SolidColorBrush x:Key="ButtonContentDisabledBrush" Color="#FF4A4E51"/>

    <!-- Background Brush -->

    <LinearGradientBrush x:Key="ButtonBackgroundBrush" EndPoint="0.5,1" StartPoint="0.5,0">
        <GradientStop Color="#FF202C45" Offset="0"/>
        <GradientStop Color="#FF162034" Offset="1"/>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ButtonPressedBackgroundBrush" EndPoint="0.5,1" StartPoint="0.5,0.0">
        <GradientStop Color="#FF1A3C65" Offset="0"/>
        <GradientStop Color="#FF1A3C65" Offset="1.0"/>
        <GradientStop Color="#FF0C1C31" Offset="0.35"/>
        <GradientStop Color="#FF0C1C31" Offset="0.65"/>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ButtonCheckedBackgroundBrush" EndPoint="0.5,1" StartPoint="0.5,0">
        <GradientStop Color="#FF3398FD" Offset="0"/>
        <GradientStop Color="#FF1A4E85" Offset="1"/>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ButtonDisabledBackgroundBrush" EndPoint="0.5,1" StartPoint="0.5,0">
        <GradientStop Color="#FF1B2436" Offset="0"/>
        <GradientStop Color="#FF182131" Offset="1"/>
    </LinearGradientBrush>


    <!-- Border Brush -->

    <LinearGradientBrush x:Key="ButtonBorderBrush" EndPoint="1.0,1.0" StartPoint="0.0,0.0">
        <GradientStop Color="#FF9E9E9E" Offset="0"/>
        <GradientStop Color="#FF415785" Offset="1"/>
    </LinearGradientBrush>

    <SolidColorBrush x:Key="ButtonHighlightedBorderBrush" Color="#FF3399FF"/>
    <SolidColorBrush x:Key="ButtonDisabledBorderBrush" Color="#FF424346"/>



    <!--*******************************-->
    <!--        TextBox Brushes        -->
    <!--*******************************-->

    <SolidColorBrush x:Key="TextBoxBorderBrush" Color="#FF265184"/>
    <SolidColorBrush x:Key="TextBoxBackgroundBrush" Color="#FF0F121D"/>
    <SolidColorBrush x:Key="TextBoxMouseOverBorderBrush" Color="#FF3283D8"/>
    <SolidColorBrush x:Key="TextBoxFocusedBorderBrush" Color="#FF3283D8"/>

    <!--*****************************-->
    <!--      DatePicker Brushes     -->
    <!--*****************************-->

    <SolidColorBrush x:Key="DatePickerBorderBrush" Color="#FF265184"/>
    <SolidColorBrush x:Key="DatePickerBackgroundBrush" Color="#FF0F121D"/>
    <SolidColorBrush x:Key="DatePickerMouseOverBorderBrush" Color="#FF3283D8"/>
    <SolidColorBrush x:Key="DatePickerFocusedBorderBrush" Color="#FF3283D8"/>

    <!--*******************************-->
    <!--        TabControl Brushes        -->
    <!--*******************************-->

    <SolidColorBrush x:Key="TabControlBackgroundBrush" Color="#FF1B2436"/>


    <!--*******************************-->
    <!--        TabItem Brushes        -->
    <!--*******************************-->

    <SolidColorBrush x:Key="TabItemBackgroundBrush" Color="#FF282828"/>
    <SolidColorBrush x:Key="TabItemNormalBorderBrush" Color="#FF3F4246"/>
    <SolidColorBrush x:Key="TabItemMouseOverBorderBrush" Color="#FF3399FF"/>
    <SolidColorBrush x:Key="TabItemSelectBorderBrush" Color="#FF20548B"/>
    <SolidColorBrush x:Key="TabItemSelectForegroundBrush" Color="#FFBFD1FF"/>
    <SolidColorBrush x:Key="TabItemNoSelectForegroundBrush" Color="#FF999999"/>

    <LinearGradientBrush x:Key="SelectedTabItemBackgroundBrush" EndPoint="0.5,0.0" StartPoint="0.5,1.0">
        <GradientStop Color="#FF1C2639" Offset="0"/>
        <GradientStop Color="#FF20314B" Offset="1"/>
    </LinearGradientBrush>

    <!--*******************************-->
    <!--       ComboBox Brushes        -->
    <!--*******************************-->

    <SolidColorBrush x:Key="ComboBoxToggleButtonBorderBrush" Color="#FF265184"/>
    <SolidColorBrush x:Key="ComboBoxToggleButtonBackgroundBrush" Color="#FF0F121D"/>

    <SolidColorBrush x:Key="ComboBoxPopupBackgroundBrush" Color="#FF0F121D"/>
    <SolidColorBrush x:Key="ComboBoxPopupBorderBrush" Color="#FF265184"/>

    <SolidColorBrush x:Key="ComboBoxArrowForegroundBrush" Color="#FF818FA7"/>
    <SolidColorBrush x:Key="ComboBoxArrowDownForegroundBrush" Color="#FFBFD1FF"/>
    <SolidColorBrush x:Key="ComboBoxArrowButtonBorderBrush" Color="#FF3D5791"/>
    <SolidColorBrush x:Key="ComboBoxArrowButtonDownBorderBrush" Color="#FF3399FF"/>

    <SolidColorBrush x:Key="ComboBoxTextForegroundBrush" Color="#FFBFD1FF"/>

    <LinearGradientBrush x:Key="ComboBoxButtonBorderBrush" EndPoint="0.5,0.0" StartPoint="0.5,1.0">
        <GradientStop Color="#FF202C45" Offset="0"/>
        <GradientStop Color="#FF213755" Offset="1"/>
    </LinearGradientBrush>

    <RadialGradientBrush x:Key="ComboBoxButtonCheckedBackgroundBrush">
        <GradientStop Color="#FF161A3A" Offset="0"/>
        <GradientStop Color="#FF25507B" Offset="1"/>
    </RadialGradientBrush>


    <!--*******************************-->
    <!--     RadioButton Brushes       -->
    <!--*******************************-->

    <SolidColorBrush x:Key="RadioButtonBackgroundBrush" Color="#FF0E1019"/>
    <SolidColorBrush x:Key="RadioButtonBorderBrush" Color="#FF21557F"/>
    <SolidColorBrush x:Key="RadioButtonSelectedBrush" Color="#FF3399FE"/>


    <!--****************************-->
    <!--     CheckBox Brushes       -->
    <!--****************************-->

    <SolidColorBrush x:Key="CheckBoxBackgroundBrush" Color="#FF111927"/>
    <SolidColorBrush x:Key="CheckBoxBorderBrush" Color="#FF27558E"/>
    <SolidColorBrush x:Key="CheckBoxCheckedBrush" Color="#FF3399FE"/>
    <SolidColorBrush x:Key="CheckBoxShadeBorderBrush" Color="#FF141F30"/>

    <!--************************-->
    <!--  ProgressBar Brushes   -->
    <!--************************-->

    <SolidColorBrush x:Key="ProgressBarBorderBrush" Color="#FFAFB3B8"/>
    <SolidColorBrush x:Key="ProgressBarBackgroundBrush" Color="#FF231916"/>

    <LinearGradientBrush x:Key="ProgressBarFillBrush" EndPoint="0.5,0.0" StartPoint="0.5,1.0">
        <GradientStop Color="#FF3975B4" Offset="0"/>
        <GradientStop Color="#FF3975B4" Offset="1"/>
        <GradientStop Color="#FF0A539E" Offset="0.5"/>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ProgressBarFillBrush2" EndPoint="0.5,0.0" StartPoint="0.5,1.0">
        <GradientStop Color="#FF5999DA" Offset="0"/>
        <GradientStop Color="#FF5999DA" Offset="1"/>
        <GradientStop Color="#FF4288CF" Offset="0.5"/>
    </LinearGradientBrush>


    <!--************************-->
    <!--    Slider Brushes      -->
    <!--************************-->

    <SolidColorBrush x:Key="SliderNormalBorderBrush" Color="#FF336688"/>
    <SolidColorBrush x:Key="SliderTruckBackgroundBrush" Color="#FF000000"/>
    <LinearGradientBrush x:Key="SliderThambBackgroundBrush" EndPoint="0.5,0" StartPoint="0.5,1.0">
        <GradientStop Color="#FF7FA0D1" Offset="0"/>
        <GradientStop Color="#FFD9E5FC" Offset="1"/>
    </LinearGradientBrush>

    <SolidColorBrush x:Key="SliderMouseOverBorderBrush" Color="#FF3399FF"/>
    <LinearGradientBrush x:Key="SliderMouseOverThambBrush" EndPoint="0.5,0" StartPoint="0.5,1.0">
        <GradientStop Color="#FF2A75D1" Offset="0"/>
        <GradientStop Color="#FF48A8FC" Offset="1"/>
    </LinearGradientBrush>
    <SolidColorBrush x:Key="SliderThambForegroundBrush" Color="#FF224466"/>
    <SolidColorBrush x:Key="SliderDisabledBrush" Color="#FF444444"/>


    <!--************************-->
    <!--   ScrollBar Brushes    -->
    <!--************************-->

    <!-- Thumb-->
    <LinearGradientBrush x:Key="ScrollBarThumbBackgroundBrush" EndPoint="0.5,0" StartPoint="0.5,1">
        <GradientStop Color="#FF202C45" Offset="0"/>
        <GradientStop Color="#FF213755" Offset="1.0"/>
    </LinearGradientBrush>
    <SolidColorBrush x:Key="ScrollBarThumbForegroundBrush" Color="#FF818FA7"/>
    <SolidColorBrush x:Key="ScrollBarThumbBorderBrush" Color="#FF3D5791"/>

    <LinearGradientBrush x:Key="ScrollBarThumbVerticalDraggingBrush" EndPoint="0.0,0.5" StartPoint="1.0,0.5">
        <GradientStop Color="#FF25507B" Offset="0"/>
        <GradientStop Color="#FF25507B" Offset="1"/>
        <GradientStop Color="#FF16243A" Offset="0.5"/>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="ScrollBarThumbHorizontalDraggingBrush" EndPoint="0.5,0.0" StartPoint="0.5,1.0">
        <GradientStop Color="#FF25507B" Offset="0"/>
        <GradientStop Color="#FF25507B" Offset="1"/>
        <GradientStop Color="#FF16243A" Offset="0.5"/>
    </LinearGradientBrush>

    <!--Repeat Button-->
    <LinearGradientBrush x:Key="ScrollBarRepeatButtonBackgroundBrush" EndPoint="0.5,0" StartPoint="0.5,1">
        <GradientStop Color="#FF202C45" Offset="0"/>
        <GradientStop Color="#FF213755" Offset="1.0"/>
    </LinearGradientBrush>
    <SolidColorBrush x:Key="ScrollBarRepeatButtonForegroundBrush" Color="#FF818FA7"/>
    <SolidColorBrush x:Key="ScrollBarRepeatButtonBorderBrush" Color="#FF3D5791"/>
    <LinearGradientBrush x:Key="ScrollBarRepeatButtonPressedBrush" EndPoint="0.5,0.0" StartPoint="0.5,1.0">
        <GradientStop Color="#FF25507B" Offset="0"/>
        <GradientStop Color="#FF25507B" Offset="1"/>
        <GradientStop Color="#FF16243A" Offset="0.5"/>
    </LinearGradientBrush>


    <SolidColorBrush x:Key="ScrollBarBorderBrush" Color="#FF263142"/>
    <SolidColorBrush x:Key="ScrollBarMouseOverBorderBrush" Color="#FF3399FF"/>


    <LinearGradientBrush x:Key="ScrollBarBackgroundBrush" EndPoint="1,0.5" StartPoint="0,0.5">
        <GradientStop Color="#FF0F1522" Offset="0"/>
        <GradientStop Color="#FF182438" Offset="1"/>
    </LinearGradientBrush>


    <!--************************-->
    <!--   ListView Brushes    -->
    <!--************************-->


    <SolidColorBrush x:Key="ListViewItemForegroundBrush" Color="#FF668BC8"/>
    <SolidColorBrush x:Key="ListViewItemSelectedForegroundBrush" Color="#FFFFFFFF"/>
    <SolidColorBrush x:Key="ListViewItemSelectedBackgroundBrush" Color="#FF2563A5"/>
    <SolidColorBrush x:Key="ListViewBorderBrush" Color="#FF305886"/>

    <SolidColorBrush x:Key="ListViewHeaderForegroundBrush" Color="#FF888DAC"/>
    <SolidColorBrush x:Key="ListViewHeaderBackgroundBrush" Color="#FF223A59"/>

    <!-- Tail Background-->
    <DrawingBrush x:Key="ListViewTailDrawingBrush"
                  Stretch="Fill"
                  AlignmentX="Left"
                  AlignmentY="Top"
                  TileMode="Tile"
                  Viewport="0,0,1,36"
                  ViewportUnits="Absolute">
        <DrawingBrush.Drawing>
            <DrawingGroup>
                <GeometryDrawing Brush="#FF111A2A">
                    <GeometryDrawing.Geometry>
                        <RectangleGeometry Rect="0,0,20,20"/>
                    </GeometryDrawing.Geometry>
                </GeometryDrawing>
                <GeometryDrawing Brush="#FF0D101A">
                    <GeometryDrawing.Geometry>
                        <RectangleGeometry Rect="0,20,20,20"/>
                    </GeometryDrawing.Geometry>
                </GeometryDrawing>
            </DrawingGroup>
        </DrawingBrush.Drawing>
    </DrawingBrush>

    <SolidColorBrush x:Key="ListViewCheckBoxBrushBrush" Color="#FF3399FF"/>


    <!--************************-->
    <!--    ListBox Brushes     -->
    <!--************************-->

    <SolidColorBrush x:Key="ListBoxItemForegroundBrush" Color="#FFBFD1FF"/>
    <SolidColorBrush x:Key="ListBoxItemSelectedForegroundBrush" Color="#FFFFFFFF"/>
    <SolidColorBrush x:Key="ListBoxItemSelectedBackgroundBrush" Color="#FF2563A5"/>
    <SolidColorBrush x:Key="ListBoxBorderBrush" Color="#FF265184"/>
    <SolidColorBrush x:Key="ListBoxBackgroundBrush" Color="#FF0F121D"/>


    <!--***********************-->
    <!--    Dialog Brushes     -->
    <!--***********************-->

    <SolidColorBrush x:Key="DialogTitleForegroungBrush" Color="#FFBFD1FF"/>
    <LinearGradientBrush x:Key="DialogTitleBackgroundBrush" EndPoint="0.5,1.0" StartPoint="0.5,0.0">
        <GradientStop Color="#FF21334F" Offset="0"/>
        <GradientStop Color="#FF1B2436" Offset="1"/>
    </LinearGradientBrush>
    <LinearGradientBrush x:Key="DialogBottomBackgroundBrush" EndPoint="0.5,1.0" StartPoint="0.5,0.0">
        <GradientStop Color="#FF21334F" Offset="0"/>
        <GradientStop Color="#FF1B2436" Offset="1"/>
    </LinearGradientBrush>
    <SolidColorBrush x:Key="DialogBodyBackgroundBrush" Color="#FF3F5276"/>
    <SolidColorBrush x:Key="DialogBodyForegroungBrush" Color="#FFBFD1FF"/>

    <SolidColorBrush x:Key="DialogInnerBorderBrush" Color="#FF9598A8"/>
    <SolidColorBrush x:Key="DialogOuterBorderBrush" Color="#FF000001"/>

    <SolidColorBrush x:Key="DialogDividerLineUpBrush" Color="#FF101112"/>
    <SolidColorBrush x:Key="DialogDividerLineDownBrush" Color="#FF546C8D"/>

    <SolidColorBrush x:Key="DialogEnclosureLineBrush" Color="#FF637AA5"/>


    <!--**********************-->
    <!--     Menu Brushes     -->
    <!--**********************-->

    <SolidColorBrush x:Key="MenuBackgroundBrush" Color="#FF21334F"/>
    <SolidColorBrush x:Key="MenuSelectedBackgroundBrush" Color="#FF2C70B9"/>
    <SolidColorBrush x:Key="MenuForegroundBrush" Color="#FFBFD1FF"/>
    <SolidColorBrush x:Key="MenuSelectedForegroundBrush" Color="#FFFFFFFF"/>
    <SolidColorBrush x:Key="MenuBorderBrush" Color="#FF265184"/>



    <!--******************************-->
    <!--    MainTaskWindow Brushes   -->
    <!--******************************-->

    <LinearGradientBrush x:Key="MainTaskBrush" StartPoint="0.5,1.0" EndPoint="0.5,0.0">
        <GradientStop Color="#FF121A2B" Offset="0.0"/>
        <GradientStop Color="#FF2A3D63" Offset="1.0"/>
    </LinearGradientBrush>

    <SolidColorBrush x:Key="MainTaskBorder" Color="#68D7FC"/>
    <SolidColorBrush x:Key="MainTaskShellBackgroundBrush" Color="#FF5A5D7B"/>

    <SolidColorBrush x:Key="{ComponentResourceKey TypeInTargetAssembly={x:Type local:PropertyGrid}, ResourceId=PropertiesBackgroundBrush}" Color="#FF333333"/>
    <SolidColorBrush x:Key="ListBorder" Color="#828790"/>

    <LinearGradientBrush x:Key="{ComponentResourceKey TypeInTargetAssembly={x:Type local:PropertyGrid}, ResourceId=HeaderBackgroundBrush}" EndPoint="0.508,0.893" StartPoint="0.508,0.107">
        <GradientStop Color="#FF2B2B2B" Offset="0"/>
        <GradientStop Color="#FF4E4E4E" Offset="1"/>
        <GradientStop Color="#FF474747" Offset="0.519"/>
    </LinearGradientBrush>

    <SolidColorBrush x:Key="{ComponentResourceKey TypeInTargetAssembly={x:Type local:PropertyGrid}, ResourceId=HeaderBorderBrush}" Color="#FF161616"/>
    <LinearGradientBrush x:Key="{ComponentResourceKey TypeInTargetAssembly={x:Type local:PropertyGrid}, ResourceId=HeaderGlassFillBrush}" EndPoint="0.5,0.993" StartPoint="0.5,0.007">
        <GradientStop Color="#FF0C0C0C" Offset="0"/>
        <GradientStop Color="#FF101010" Offset="1"/>
        <GradientStop Color="#33636363" Offset="0.505"/>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="{ComponentResourceKey TypeInTargetAssembly={x:Type local:PropertyGrid}, ResourceId=HeaderHighlighBackgroundBrush}" EndPoint="0.508,0.893" StartPoint="0.508,0.107">
        <GradientStop Color="#FF000000" Offset="0"/>
        <GradientStop Color="#FF000000" Offset="1"/>
        <GradientStop Color="#FF525252" Offset="0.519"/>
    </LinearGradientBrush>

    <LinearGradientBrush x:Key="{ComponentResourceKey TypeInTargetAssembly={x:Type local:PropertyGrid}, ResourceId=HeaderHighlighGlassFillBrush}" EndPoint="0.5,0.993" StartPoint="0.5,0.007">
        <GradientStop Color="#FF0C0C0C" Offset="0"/>
        <GradientStop Color="#FF101010" Offset="1"/>
        <GradientStop Color="#33636363" Offset="0.505"/>
    </LinearGradientBrush>
    <SolidColorBrush x:Key="{ComponentResourceKey TypeInTargetAssembly={x:Type local:PropertyGrid}, ResourceId=ContentBackgroundBrush}" Color="#FF333333"/>
    <SolidColorBrush x:Key="{ComponentResourceKey TypeInTargetAssembly={x:Type local:PropertyGrid}, ResourceId=PropertiesForegroundBrush}" Color="#FFFFFFFF"/>

    <DataTemplate DataType="{x:Type data:PropertyCollection}">
        <ItemsControl ItemsSource="{Binding Path=Items}" />
    </DataTemplate>

    <DataTemplate DataType="{x:Type data:PropertyCategory}">
        <Expander Header="{Binding Category}" IsExpanded="True">
            <ItemsControl ItemsSource="{Binding Path=Items}" />
        </Expander>
    </DataTemplate>

    <DataTemplate DataType="{x:Type data:Property}">
        <DockPanel Margin="4">
            <TextBlock DockPanel.Dock="Left" Width="80" Margin="0,0,8,0" TextAlignment="Right" VerticalAlignment="Center" Text="{Binding Mode=OneTime, Path=Name}" />
            <ContentControl
				VerticalAlignment="Center"
				Content="{Binding Mode=OneWay}"
				ContentTemplateSelector="{StaticResource propertyTemplateSelector}" />
        </DockPanel>
    </DataTemplate>

    <!-- CLR & Custom Types Data Templates -->
    <DataTemplate x:Key="{ComponentResourceKey TypeInTargetAssembly={x:Type local:PropertyGrid}, ResourceId=default}">
        <TextBox IsReadOnly="{Binding Path=IsReadOnly}">
            <TextBox.Text>
                <Binding Mode="TwoWay" Path="Value">
                    <Binding.ValidationRules>
                        <ExceptionValidationRule />
                    </Binding.ValidationRules>
                </Binding>
            </TextBox.Text>
        </TextBox>
    </DataTemplate>

    <DataTemplate x:Key="{ComponentResourceKey TypeInTargetAssembly={x:Type local:PropertyGrid}, ResourceId={x:Type clr:Boolean}}">
        <CheckBox IsEnabled="{Binding Path=IsWriteable}" IsChecked="{Binding Path=Value}" />
    </DataTemplate>

    <DataTemplate x:Key="{ComponentResourceKey TypeInTargetAssembly={x:Type local:PropertyGrid}, ResourceId={x:Type clr2:IList}}">
        <ListBox ItemsSource="{Binding Path=Value}" />
    </DataTemplate>

    <DataTemplate x:Key="{ComponentResourceKey TypeInTargetAssembly={x:Type local:PropertyGrid}, ResourceId={x:Type clr:Enum}}">
        <ComboBox SelectedValue="{Binding Path=Value}">
            <ComboBox.ItemsSource>
                <Binding Path="Value">
                    <Binding.Converter>
                        <converters:EnumTypeConverter />
                    </Binding.Converter>
                </Binding>
            </ComboBox.ItemsSource>
        </ComboBox>
    </DataTemplate>

    <!-- PropertyGrid Style -->
    <Style TargetType="{x:Type local:PropertyGrid}">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate>
                    <DockPanel LastChildFill="True">
                        <Border DockPanel.Dock="Top" Width="Auto" Height="30" CornerRadius="5,5,0,0" BorderThickness="1,1,1,1" BorderBrush="{DynamicResource {ComponentResourceKey TypeInTargetAssembly={x:Type local:PropertyGrid}, ResourceId=HeaderBorderBrush}}" HorizontalAlignment="Stretch" VerticalAlignment="Stretch"
								Background="{DynamicResource {ComponentResourceKey TypeInTargetAssembly={x:Type local:PropertyGrid}, ResourceId=HeaderBackgroundBrush}}">
                            <TextBlock Text="Properties" Width="Auto" Height="Auto" Foreground="#FFFFFFFF" Margin="8" HorizontalAlignment="Left" VerticalAlignment="Center" />
                        </Border>
                        <ScrollViewer VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Disabled">
                            <ItemsControl
									ItemsSource="{TemplateBinding local:PropertyGrid.Properties}"
									Background="{DynamicResource {ComponentResourceKey
									TypeInTargetAssembly={x:Type local:PropertyGrid},
									ResourceId=PropertiesBackgroundBrush}}" />
                        </ScrollViewer>
                    </DockPanel>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!--								-->
    <!-- General Styles -->
    <!--								-->

    <!-- Slider Thumb Style -->
    <Style x:Key="NADRThumbStyle" TargetType="{x:Type Thumb}">
        <Setter Property="OverridesDefaultStyle" Value="true"/>
        <Setter Property="Height" Value="22"/>
        <Setter Property="Width" Value="11"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Thumb}">
                    <Canvas SnapsToDevicePixels="true">
                        <Canvas.RenderTransform>
                            <TranslateTransform X="5.5" Y="11"/>
                        </Canvas.RenderTransform>
                        <Path Fill="{StaticResource DefaultControlForegroundBrush}" Stretch="Fill" Stroke="{StaticResource DefaultControlBorderBrush}" x:Name="path" Width="15.163" Height="13.358" Data="M0.4875,2.085 L-6.4255012,8.0975 -6.47271,14.443798 7.690273,14.355796 7.5874902,8.1977551 z" Canvas.Left="-7.125" Canvas.Top="2.085"/>
                        <Rectangle Fill="{StaticResource FocusedControlBorderBrush}" RadiusX="0.588" RadiusY="0.588" Width="2.433" Height="5.11" Canvas.Left="-0.282" Canvas.Top="-1.975"/>
                        <Path Fill="{StaticResource DefaultControlForegroundBrush}" Stretch="Fill" Stroke="{StaticResource DefaultControlBorderBrush}" Width="1" Height="4" Data="M-1.958,7.8685 L-1.9913333,13.218" Canvas.Left="-2.071" Canvas.Top="8.839"/>
                        <Path Stretch="Fill" Width="1" Height="4" Data="M-1.958,7.8685 L-1.9913333,13.218" Stroke="{StaticResource DefaultControlBorderBrush}" Canvas.Left="1.317" Canvas.Top="8.839"/>
                    </Canvas>
                    <ControlTemplate.Triggers>
                        <Trigger Property="MinWidth" Value="0"/>
                        <Trigger Property="MinWidth" Value="0"/>
                        <Trigger Property="IsMouseOver" Value="true">
                            <Setter Property="Fill" TargetName="path" Value="{StaticResource FocusedControlBorderBrush}"/>
                        </Trigger>
                        <Trigger Property="Foreground" Value="Orange"/>
                        <Trigger Property="IsDragging" Value="true"/>
                        <Trigger Property="IsEnabled" Value="false"/>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!-- Slider Repeat Button Style -->
    <Style x:Key="SliderRepeatButtonStyle" TargetType="{x:Type RepeatButton}">
        <Setter Property="OverridesDefaultStyle" Value="true"/>
        <Setter Property="IsTabStop" Value="false"/>
        <Setter Property="Focusable" Value="false"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type RepeatButton}">
                    <Border Background="Transparent"/>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!-- WPG Slider Style -->
    <Style  TargetType="{x:Type Slider}">
        <Setter Property="Stylus.IsPressAndHoldEnabled" Value="false"/>
        <Setter Property="Background" Value="Transparent"/>
        <Setter Property="Foreground" Value="#FFA1A192"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Slider}">
                    <Border SnapsToDevicePixels="true" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Padding="2,0,2,2">
                        <Grid>
                            <Grid.RowDefinitions>
                                <RowDefinition Height="Auto"/>
                                <RowDefinition Height="Auto" MinHeight="22"/>
                                <RowDefinition Height="Auto" MinHeight="0"/>
                            </Grid.RowDefinitions>
                            <TickBar Visibility="Collapsed" x:Name="TopTick" Height="4" Grid.Row="1" Fill="{TemplateBinding Foreground}" Placement="Top" d:LayoutOverrides="GridBox" Margin="0,0,0,18"/>
                            <TickBar Visibility="Collapsed" x:Name="BottomTick" Height="4" Grid.Row="2" Fill="{TemplateBinding Foreground}" Placement="Bottom" Margin="0,0,0,-4"/>

                            <Border Name="trackBorder"
                Margin="5,0"
                VerticalAlignment="center"
                Height="6.0"
                Grid.Row="1"
                Background="{DynamicResource ButtonBackgroundBrush}"
                BorderBrush="{DynamicResource ButtonBorderBrush}"
                BorderThickness="0.5,0.5,0.5,0.5"
                CornerRadius="1"/>

                            <Track x:Name="PART_Track" Grid.Row="1">
                                <Track.DecreaseRepeatButton>
                                    <RepeatButton Style="{StaticResource SliderRepeatButtonStyle}" Command="{x:Static Slider.DecreaseLarge}"/>
                                </Track.DecreaseRepeatButton>
                                <Track.IncreaseRepeatButton>
                                    <RepeatButton Style="{StaticResource SliderRepeatButtonStyle}" Command="{x:Static Slider.IncreaseLarge}"/>
                                </Track.IncreaseRepeatButton>
                                <Track.Thumb>
                                    <Thumb x:Name="Thumb" Style="{DynamicResource NADRThumbStyle}"/>
                                </Track.Thumb>
                            </Track>

                        </Grid>
                    </Border>
                    <ControlTemplate.Triggers>

                        <!-- Mouse Over -->
                        <Trigger Property="IsMouseOver" Value="True">
                            <Setter TargetName="trackBorder" Property="BorderBrush" Value="{StaticResource SliderMouseOverBorderBrush}" />
                            <Setter TargetName="Thumb" Property="Background" Value="{StaticResource SliderMouseOverThambBrush}"/>
                        </Trigger>

                        <!-- Foucs -->
                        <Trigger Property="IsFocused" Value="True">
                            <Setter TargetName="Thumb" Property="Background" Value="{StaticResource SliderMouseOverThambBrush}"/>
                        </Trigger>

                        <!-- Disabled-->
                        <Trigger Property="IsEnabled" Value="False">
                            <Setter TargetName="trackBorder" Property="BorderBrush" Value="{StaticResource SliderDisabledBrush}" />
                            <Setter Property="Foreground" Value="{StaticResource SliderDisabledBrush}"/>
                            <Setter Property="Background" TargetName="Thumb" Value="{DynamicResource SliderDisabledBrush}"/>
                            <Setter Property="Foreground" TargetName="Thumb" Value="{DynamicResource SliderDisabledBrush}"/>
                            <Setter Property="BorderBrush" TargetName="Thumb" Value="{DynamicResource SliderDisabledBrush}"/>
                            <Setter Property="IsEnabled" TargetName="Thumb" Value="False"/>
                        </Trigger>

                        <Trigger Property="TickPlacement" Value="TopLeft">
                            <Setter Property="Visibility" TargetName="TopTick" Value="Visible"/>
                        </Trigger>
                        <Trigger Property="TickPlacement" Value="BottomRight">
                            <Setter Property="Visibility" TargetName="BottomTick" Value="Visible"/>
                        </Trigger>
                        <Trigger Property="TickPlacement" Value="Both">
                            <Setter Property="Visibility" TargetName="TopTick" Value="Visible"/>
                            <Setter Property="Visibility" TargetName="BottomTick" Value="Visible"/>
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!-- WPG Button Style -->
    <!--<Style BasedOn="{x:Null}" TargetType="{x:Type Button}">
		<Setter Property="BorderBrush" Value="{StaticResource DefaultControlBorderBrush}"/>
		<Setter Property="Template">
			<Setter.Value>
				<ControlTemplate TargetType="{x:Type Button}">
					<Grid>
						<Grid.RowDefinitions>
							<RowDefinition Height="0.5*"/>
							<RowDefinition Height="0.5*"/>
						</Grid.RowDefinitions>

						<Rectangle x:Name="buttonShape"
              RadiusX="4"
              RadiusY="4"
              Grid.RowSpan="2"
              RenderTransformOrigin="0.5,0.5"
              Margin="0,-0.333,0,0.333"
              Fill="{DynamicResource {ComponentResourceKey ResourceId=HeaderHighlighGlassFillBrush, TypeInTargetAssembly={x:Type local:PropertyGrid}}}"
              Stroke="{TemplateBinding Button.BorderBrush}"
							/>

						<Rectangle x:Name="buttonShapeBubble"
              Opacity="0.6"
              RadiusX="3.333"
              RadiusY="3.333"
              Margin="5,3,5,0"
              VerticalAlignment="Stretch"
              Height="Auto"
              Grid.RowSpan="1"
              RenderTransformOrigin="0.5,0.5"
              Fill="{DynamicResource {ComponentResourceKey ResourceId=HeaderBackgroundBrush, TypeInTargetAssembly={x:Type local:PropertyGrid}}}"
							/>

						<ContentPresenter x:Name="contentPresenter"
               SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"
               HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
               Margin="8,4,8,4"
               VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
               Grid.RowSpan="2"
               RecognizesAccessKey="True"
               RenderTransformOrigin="0.5,0.5"
							/>

					</Grid>

					<ControlTemplate.Triggers>

			
						<Trigger Property="IsEnabled" Value="False">
							<Setter Property="Fill" TargetName="buttonShape" Value="{StaticResource DisabledControlBrush}" />
							<Setter Property="Stroke" TargetName="buttonShape" Value="{StaticResource DisabledControlBorderBrush}"/>
							<Setter Property="Fill" TargetName="buttonShapeBubble" Value="{StaticResource DisabledControlGlossyBrush}"/>
							<Setter Property="Foreground" Value="{StaticResource DisabledControlForegroundBrush}"/>
						</Trigger>

			
						<Trigger Property="IsEnabled" Value="True">
							<Setter Property="Foreground" Value="{StaticResource DefaultControlForegroundBrush}"/>
						</Trigger>

			
						<Trigger Property="IsFocused" Value="True">
							<Setter Property="Stroke" TargetName="buttonShape" Value="{StaticResource FocusedControlBorderBrush}" />
							<Setter Property="Fill" TargetName="buttonShape" Value="{DynamicResource {ComponentResourceKey ResourceId=HeaderGlassFillBrush, TypeInTargetAssembly={x:Type local:PropertyGrid}}}"/>
							<Setter Property="Fill" TargetName="buttonShapeBubble" Value="{DynamicResource {ComponentResourceKey ResourceId=HeaderBackgroundBrush, TypeInTargetAssembly={x:Type local:PropertyGrid}}}"/>
						</Trigger>

			
						<Trigger Property="IsMouseOver" Value="True">
							<Setter Property="Stroke" TargetName="buttonShape" Value="{StaticResource HighlightedControlBorderBrush}" />
							<Setter Property="Fill" TargetName="buttonShape" Value="{DynamicResource {ComponentResourceKey ResourceId=PropertiesBackgroundBrush, TypeInTargetAssembly={x:Type local:PropertyGrid}}}"/>
							<Setter Property="Fill" TargetName="buttonShapeBubble" Value="{DynamicResource {ComponentResourceKey ResourceId=HeaderBackgroundBrush, TypeInTargetAssembly={x:Type local:PropertyGrid}}}"/>
						</Trigger>

			
						<Trigger Property="IsPressed" Value="True">
							<Setter Property="RenderTransform" TargetName="contentPresenter">
								<Setter.Value>
									<TransformGroup>
										<TranslateTransform X="1" Y="1" />
									</TransformGroup>
								</Setter.Value>
							</Setter>
							<Setter Property="Fill" TargetName="buttonShape" Value="{DynamicResource {ComponentResourceKey ResourceId=HeaderBorderBrush, TypeInTargetAssembly={x:Type local:PropertyGrid}}}"/>
							<Setter Property="Fill" TargetName="buttonShapeBubble" Value="{DynamicResource {ComponentResourceKey ResourceId=PropertiesBackgroundBrush, TypeInTargetAssembly={x:Type local:PropertyGrid}}}"/>
						</Trigger>

					</ControlTemplate.Triggers>
				</ControlTemplate>
			</Setter.Value>
		</Setter>
	</Style>-->

    <!-- WPG Expander ToggleButton -->
    <ControlTemplate x:Key="ExpanderToggleButton" TargetType="{x:Type ToggleButton}">
        <Grid>
            <Rectangle Margin="0,0,0,0" x:Name="Rectangle" Fill="Transparent"/>
            <Path HorizontalAlignment="Center" x:Name="Up_Arrow" VerticalAlignment="Center" Fill="#FFFFFFFF" Data="M 0 0 L 4 4 L 8 0 Z" RenderTransformOrigin="0.5,0.5">
                <Path.RenderTransform>
                    <TransformGroup>
                        <ScaleTransform ScaleX="1" ScaleY="1"/>
                        <SkewTransform AngleX="0" AngleY="0"/>
                        <RotateTransform Angle="-90"/>
                        <TranslateTransform X="0" Y="0"/>
                    </TransformGroup>
                </Path.RenderTransform>
            </Path>
            <Path Visibility="Collapsed" HorizontalAlignment="Center" x:Name="Down_Arrow" VerticalAlignment="Center" Fill="{DynamicResource GlyphBrush}" Data="M 0 4 L 4 0 L 8 4 Z" RenderTransformOrigin="0.5,0.5">
                <Path.RenderTransform>
                    <TransformGroup>
                        <ScaleTransform ScaleX="1" ScaleY="1"/>
                        <SkewTransform AngleX="0" AngleY="0"/>
                        <RotateTransform Angle="180"/>
                        <TranslateTransform X="0" Y="0"/>
                    </TransformGroup>
                </Path.RenderTransform>
            </Path>
        </Grid>
        <ControlTemplate.Triggers>
            <Trigger Property="IsChecked" Value="true">
                <Setter Property="Visibility" Value="Visible" TargetName="Down_Arrow"/>
                <Setter Property="Visibility" Value="Collapsed" TargetName="Up_Arrow"/>
                <Setter Property="OpacityMask" TargetName="Down_Arrow" Value="#FF000000"/>
                <Setter TargetName="Down_Arrow" Property="Fill" Value="#FFFFFFFF"/>
            </Trigger>
        </ControlTemplate.Triggers>
    </ControlTemplate>

    <!-- WPG Expander Style -->
    <Style TargetType="{x:Type Expander}">
        <Setter Property="Padding" Value="8"/>
        <Setter Property="Background" Value="{DynamicResource ExpanderBackgroundBrush}"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Expander}">
                    <Grid>
                        <Grid.RowDefinitions>
                            <RowDefinition Height="Auto"/>
                            <RowDefinition Height="*" x:Name="ContentRow"/>
                        </Grid.RowDefinitions>
                        <Border Grid.Row="0" x:Name="Border" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="1,1,1,1" CornerRadius="4,4,4,4">
                            <Grid>
                                <Grid.ColumnDefinitions>
                                    <ColumnDefinition Width="20"/>
                                    <ColumnDefinition Width="*"/>
                                </Grid.ColumnDefinitions>
                                <ToggleButton Template="{DynamicResource ExpanderToggleButton}" IsChecked="{Binding Path=IsExpanded, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}" OverridesDefaultStyle="True"/>
                                <ContentPresenter Grid.Column="1" Margin="4" RecognizesAccessKey="True" ContentSource="Header"/>
                            </Grid>
                        </Border>
                        <Border Visibility="Collapsed" Grid.Row="1" x:Name="ExpandSite" BorderThickness="1,0,1,1" CornerRadius="0,0,4,4" Background="{DynamicResource ExpanderBackgroundBrush}">
                            <ContentPresenter HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" Focusable="false"/>
                        </Border>
                    </Grid>
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsExpanded" Value="True">
                            <Setter Property="Visibility" Value="Visible" TargetName="ExpandSite"/>
                            <Setter Property="BorderThickness" TargetName="Border" Value="1,1,1,0"/>
                            <Setter Property="CornerRadius" TargetName="Border" Value="4,4,0,0"/>
                        </Trigger>
                        <Trigger Property="IsEnabled" Value="False">
                            <Setter Property="Background" Value="{DynamicResource DisabledBackgroundBrush}" TargetName="Border"/>
                            <Setter Property="BorderBrush" Value="{DynamicResource DisabledBorderBrush}" TargetName="Border"/>
                            <Setter Property="Foreground" Value="{DynamicResource DisabledForegroundBrush}"/>
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
        <Setter Property="Foreground" Value="{DynamicResource PropertiesForegroundBrush}"/>
    </Style>

    <!-- WPG ComboBox Toggle Button -->
    <ControlTemplate x:Key="ComboBoxToggleButton" TargetType="{x:Type ToggleButton}">
        <Grid>
            <Grid.ColumnDefinitions>
                <ColumnDefinition/>
                <ColumnDefinition Width="20"/>
            </Grid.ColumnDefinitions>
            <Rectangle Grid.ColumnSpan="2" HorizontalAlignment="Stretch" x:Name="Rectangle" VerticalAlignment="Stretch" Width="Auto" Height="Auto" RadiusX="5" RadiusY="5" Fill="{DynamicResource NormalBrush}" Stroke="{DynamicResource NormalBorderBrush}"/>
            <Rectangle Grid.Column="0" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Width="Auto" Height="Auto" RadiusX="5" RadiusY="5" Fill="{DynamicResource WindowBackgroundBrush}" Stroke="{DynamicResource NormalBorderBrush}"/>
            <Path Grid.Column="1" HorizontalAlignment="Center" x:Name="Arrow" VerticalAlignment="Center" Fill="{DynamicResource GlyphBrush}" Data="M 0 0 L 4 4 L 8 0 Z"/>
        </Grid>
        <ControlTemplate.Triggers>
            <Trigger Property="IsMouseOver" Value="true">
                <Setter Property="Fill" Value="{DynamicResource MouseOverBrush}" TargetName="Rectangle"/>
            </Trigger>
            <Trigger Property="IsChecked" Value="true">
                <Setter Property="Fill" Value="{DynamicResource PressedBrush}" TargetName="Rectangle"/>
            </Trigger>
            <Trigger Property="IsEnabled" Value="False">
                <Setter Property="Fill" Value="{DynamicResource DisabledBackgroundBrush}" TargetName="Rectangle"/>
                <Setter Property="Stroke" Value="{DynamicResource DisabledBorderBrush}" TargetName="Rectangle"/>
                <Setter Property="Foreground" Value="{DynamicResource DisabledForegroundBrush}"/>
                <Setter Property="Fill" Value="{DynamicResource DisabledForegroundBrush}" TargetName="Arrow"/>
            </Trigger>
        </ControlTemplate.Triggers>
    </ControlTemplate>

    <!-- WPG ComboBox TextBox -->
    <ControlTemplate x:Key="ComboBoxTextBox" TargetType="{x:Type TextBox}">
        <!-- This must be named as PART_ContentHost -->
        <Border x:Name="PART_ContentHost" Focusable="False" Background="{TemplateBinding Background}"/>
    </ControlTemplate>

    <!-- WPG ComboBox -->
    <!--<Style TargetType="{x:Type ComboBox}">
		<Setter Property="SnapsToDevicePixels" Value="true"/>
		<Setter Property="Template">
			<Setter.Value>
				<ControlTemplate TargetType="{x:Type ComboBox}">
					<Grid>

						<ToggleButton Grid.Column="2" Template="{DynamicResource ComboBoxToggleButton}" x:Name="ToggleButton" Focusable="false" IsChecked="{Binding Path=IsDropDownOpen, Mode=TwoWay, RelativeSource={RelativeSource TemplatedParent}}" ClickMode="Press"/>
						<ContentPresenter HorizontalAlignment="Left" Margin="3,3,23,3" x:Name="ContentSite" VerticalAlignment="Center" Content="{TemplateBinding SelectionBoxItem}" ContentTemplate="{TemplateBinding SelectionBoxItemTemplate}" ContentTemplateSelector="{TemplateBinding ItemTemplateSelector}" IsHitTestVisible="False"/>


						<TextBox Visibility="Hidden" Template="{DynamicResource ComboBoxTextBox}" HorizontalAlignment="Left" Margin="3,3,23,3" x:Name="PART_EditableTextBox" Style="{x:Null}" VerticalAlignment="Center" Focusable="True" Background="Transparent" IsReadOnly="{TemplateBinding IsReadOnly}"/>


						<Popup IsOpen="{TemplateBinding IsDropDownOpen}" Placement="Bottom" x:Name="Popup" Focusable="False" AllowsTransparency="True" PopupAnimation="Slide">
							<Grid MaxHeight="{TemplateBinding MaxDropDownHeight}" MinWidth="{TemplateBinding ActualWidth}" x:Name="DropDown" SnapsToDevicePixels="True">
								<Border x:Name="DropDownBorder" Background="{DynamicResource WindowBackgroundBrush}" BorderBrush="{DynamicResource SolidBorderBrush}" BorderThickness="1"/>
								<ScrollViewer Margin="4,6,4,6" Style="{DynamicResource PropertyGridScrollViewer}" SnapsToDevicePixels="True" HorizontalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Auto" CanContentScroll="True">

									
    <StackPanel IsItemsHost="True" KeyboardNavigation.DirectionalNavigation="Contained"/>

    </ScrollViewer>
    </Grid>
    </Popup>
    </Grid>
    <ControlTemplate.Triggers>

        <Trigger Property="HasItems" Value="false">
            <Setter Property="MinHeight" Value="95" TargetName="DropDownBorder"/>
        </Trigger>
        <Trigger Property="IsEnabled" Value="false">
            <Setter Property="Foreground" Value="{DynamicResource DisabledForegroundBrush}"/>
        </Trigger>
        <Trigger Property="IsGrouping" Value="true">
            <Setter Property="ScrollViewer.CanContentScroll" Value="false"/>
        </Trigger>
        <Trigger Property="AllowsTransparency" SourceName="Popup" Value="true">
            <Setter Property="CornerRadius" Value="4" TargetName="DropDownBorder"/>
            <Setter Property="Margin" Value="0,2,0,0" TargetName="DropDownBorder"/>
        </Trigger>
        <Trigger Property="IsEditable" Value="true">
            <Setter Property="IsTabStop" Value="false"/>
            <Setter Property="Visibility" Value="Visible" TargetName="PART_EditableTextBox"/>
            <Setter Property="Visibility" Value="Hidden" TargetName="ContentSite"/>
        </Trigger>
    </ControlTemplate.Triggers>
    </ControlTemplate>
    </Setter.Value>
    </Setter>
    </Style> -->

    <!-- WPG ComboBoxItem -->
    <!--<Style TargetType="{x:Type ComboBoxItem}">
		<Setter Property="SnapsToDevicePixels" Value="true"/>
		<Setter Property="Template">
			<Setter.Value>
				<ControlTemplate TargetType="{x:Type ComboBoxItem}">
					<Grid SnapsToDevicePixels="true">
						<Border x:Name="Border" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}"/>
						<ContentPresenter HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}"/>
					</Grid>
					<ControlTemplate.Triggers>
			
						<Trigger Property="IsHighlighted" Value="true">
							<Setter Property="Background" Value="{DynamicResource SelectedBackgroundBrush}" TargetName="Border"/>
						</Trigger>

						<Trigger Property="IsEnabled" Value="false">
							<Setter Property="Foreground" Value="{DynamicResource DisabledForegroundBrush}"/>
						</Trigger>
					</ControlTemplate.Triggers>
				</ControlTemplate>
			</Setter.Value>
		</Setter>
	</Style>-->

    <!-- WPG CheckBoxFocusVisual Style -->
    <Style x:Key="CheckBoxFocusVisual">
        <Setter Property="Control.Template">
            <Setter.Value>
                <ControlTemplate>
                    <Border>
                        <Rectangle Margin="15,0,0,0" Stroke="#60000000" StrokeThickness="1" StrokeDashArray="1 2"/>
                    </Border>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!-- WPG CheckBox Style -->
    <!--<Style TargetType="{x:Type CheckBox}">
        <Setter Property="SnapsToDevicePixels" Value="true"/>
        <Setter Property="FocusVisualStyle" Value="{DynamicResource CheckBoxFocusVisual}"/>
        <Setter Property="Background" Value="{DynamicResource WindowBackgroundBrush}"/>
        <Setter Property="BorderBrush" Value="{DynamicResource NormalBorderBrush}"/>
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type CheckBox}">

               
                    <BulletDecorator Background="Transparent">
                        <BulletDecorator.Bullet>
                            <Grid Width="13" Height="13">
                                <Border x:Name="Border" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}"/>
                                <Path x:Name="CheckMark" Stroke="{DynamicResource GlyphBrush}" StrokeThickness="2" SnapsToDevicePixels="False" Data="M 0 0 L 13 13 M 0 13 L 13 0"/>
                            </Grid>
                        </BulletDecorator.Bullet>
                        <ContentPresenter HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{TemplateBinding Padding}" VerticalAlignment="{TemplateBinding VerticalContentAlignment}" RecognizesAccessKey="True"/>
                    </BulletDecorator>

               
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsChecked" Value="false">
                            <Setter Property="Visibility" Value="Collapsed" TargetName="CheckMark"/>
                        </Trigger>
                        <Trigger Property="IsMouseOver" Value="true">
                            <Setter Property="Background" Value="{DynamicResource MouseOverBrush}" TargetName="Border"/>
                        </Trigger>
                        <Trigger Property="IsPressed" Value="true">
                            <Setter Property="Background" Value="{DynamicResource PressedBrush}" TargetName="Border"/>
                            <Setter Property="BorderBrush" Value="{DynamicResource PressedBorderBrush}" TargetName="Border"/>
                        </Trigger>
                        <Trigger Property="IsEnabled" Value="false">
                            <Setter Property="Background" Value="{DynamicResource DisabledBackgroundBrush}" TargetName="Border"/>
                            <Setter Property="BorderBrush" Value="{DynamicResource DisabledBorderBrush}" TargetName="Border"/>
                        </Trigger>
                    </ControlTemplate.Triggers>

                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>-->

    <!-- WPG TextBox Style -->
    <!--<Style TargetType="{x:Type TextBox}">
        <Setter Property="KeyboardNavigation.TabNavigation" Value="None"/>
        <Setter Property="FocusVisualStyle" Value="{x:Null}"/>
        <Setter Property="AllowDrop" Value="true"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type TextBox}">
                    <Grid>
                        <Border x:Name="Border" Background="{DynamicResource WindowBackgroundBrush}" BorderBrush="{DynamicResource SolidBorderBrush}" BorderThickness="1" Padding="2" CornerRadius="2">

               
                            <ScrollViewer Margin="0" x:Name="PART_ContentHost" Style="{DynamicResource SimpleScrollViewer}" Background="{TemplateBinding Background}"/>

                        </Border>
                    </Grid>
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsEnabled" Value="False">
                            <Setter Property="Background" Value="{DynamicResource DisabledBackgroundBrush}" TargetName="Border"/>
                            <Setter Property="BorderBrush" Value="{DynamicResource DisabledBackgroundBrush}" TargetName="Border"/>
                            <Setter Property="Foreground" Value="{DynamicResource DisabledForegroundBrush}"/>
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>-->

    <!-- WPG RepeatButton Style -->
    <Style x:Key="SimpleRepeatButton" d:IsControlPart="True" TargetType="{x:Type RepeatButton}" BasedOn="{x:Null}">
        <Setter Property="Background" Value="{DynamicResource NormalBrush}"/>
        <Setter Property="BorderBrush" Value="{DynamicResource NormalBorderBrush}"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type RepeatButton}">
                    <Grid>
                        <Border x:Name="Border" BorderThickness="{TemplateBinding BorderThickness}"/>
                        <ContentPresenter HorizontalAlignment="Center" x:Name="ContentPresenter" VerticalAlignment="Center" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}" ContentTemplateSelector="{TemplateBinding ContentTemplateSelector}"/>
                    </Grid>
                    <ControlTemplate.Triggers>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!-- Thumb Style -->
    <Style x:Key="SimpleThumbStyle" d:IsControlPart="True" TargetType="{x:Type Thumb}" BasedOn="{x:Null}">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Thumb}">
                    <Grid Margin="0,0,0,0" x:Name="Grid">
                        <Rectangle HorizontalAlignment="Stretch" x:Name="Rectangle" VerticalAlignment="Stretch" Width="8" Height="Auto" RadiusX="3" RadiusY="3" Fill="{DynamicResource DisabledBorderBrush}" Stroke="{DynamicResource NormalBorderBrush}" StrokeThickness="0"/>
                    </Grid>
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsFocused" Value="True"/>
                        <Trigger Property="IsMouseOver" Value="True">
                            <Setter Property="Fill" TargetName="Rectangle" Value="{DynamicResource DefaultForegroundBrush}"/>
                        </Trigger>
                        <Trigger Property="IsEnabled" Value="False"/>
                        <Trigger Property="IsDragging" Value="True">
                            <Setter Property="Fill" TargetName="Rectangle" Value="{DynamicResource DefaultForegroundBrush}"/>
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!-- WPG ScrollRepeatButton Style -->
    <Style x:Key="SimpleScrollRepeatButtonStyle" d:IsControlPart="True" TargetType="{x:Type RepeatButton}">
        <Setter Property="Background" Value="Transparent"/>
        <Setter Property="BorderBrush" Value="Transparent"/>
        <Setter Property="IsTabStop" Value="false"/>
        <Setter Property="Focusable" Value="false"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type RepeatButton}">
                    <Grid>
                        <Rectangle Fill="{TemplateBinding Background}" Stroke="{TemplateBinding BorderBrush}" StrokeThickness="{TemplateBinding BorderThickness}"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!-- WPG ScrollBar Style -->
    <!--<Style TargetType="{x:Type ScrollBar}">
        <Setter Property="Stylus.IsFlicksEnabled" Value="false"/>
        <Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type ScrollBar}">
                    <Border Width="14" Height="Auto" Background="{DynamicResource ExpanderBackgroundBrush}" CornerRadius="5,5,5,5">
                        <Grid x:Name="GridRoot" Width="Auto" Height="Auto">
                            <Grid.RowDefinitions>
                                <RowDefinition MaxHeight="18"/>
                                <RowDefinition Height="0.00001*"/>
                                <RowDefinition MaxHeight="18"/>
                            </Grid.RowDefinitions>

                            <RepeatButton x:Name="DecreaseRepeat" Style="{DynamicResource SimpleRepeatButton}" Command="ScrollBar.LineUpCommand" Background="{DynamicResource DisabledControlBorderBrush}" BorderBrush="{x:Null}">
                                <Grid>
                                    <Path x:Name="DecreaseArrow" StrokeThickness="1" Data="M0,7 L8,7 4,-8.437695E-15 z" Fill="{DynamicResource DisabledBorderBrush}" Margin="0,-3,0,0"/>
                                </Grid>
                            </RepeatButton>

               
                            <Track Grid.Row="1" x:Name="PART_Track" Orientation="Vertical" IsDirectionReversed="true">
                                <Track.Thumb>
                                    <Thumb Style="{DynamicResource SimpleThumbStyle}" Background="{DynamicResource GlyphBrush}"/>
                                </Track.Thumb>
                                <Track.IncreaseRepeatButton>
                                    <RepeatButton x:Name="PageUp" Style="{DynamicResource SimpleScrollRepeatButtonStyle}" Command="ScrollBar.PageDownCommand"/>
                                </Track.IncreaseRepeatButton>
                                <Track.DecreaseRepeatButton>
                                    <RepeatButton x:Name="PageDown" Style="{DynamicResource SimpleScrollRepeatButtonStyle}" Command="ScrollBar.PageUpCommand"/>
                                </Track.DecreaseRepeatButton>
                            </Track>

                            <RepeatButton Grid.Row="2" x:Name="IncreaseRepeat" Style="{DynamicResource SimpleRepeatButton}" Command="ScrollBar.LineDownCommand" Background="{DynamicResource DisabledControlBorderBrush}" BorderBrush="{x:Null}">
                                <Grid>
                                    <Path x:Name="IncreaseArrow" StrokeThickness="1" Data="M0,0 L4,7 8,0 z" Fill="{DynamicResource DisabledBorderBrush}" Margin="0,0,0,-3"/>
                                </Grid>
                            </RepeatButton>
                        </Grid>

                    </Border>

               
			
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsMouseOver" Value="True">
                            <Setter Property="Fill" TargetName="DecreaseArrow" Value="{DynamicResource DefaultForegroundBrush}"/>
                            <Setter Property="Fill" TargetName="IncreaseArrow" Value="{DynamicResource DefaultForegroundBrush}"/>
                        </Trigger>
                        <Trigger Property="Orientation" Value="Horizontal">

                            <Setter Property="LayoutTransform" TargetName="GridRoot">
                                <Setter.Value>
                                    <RotateTransform Angle="-90"/>
                                </Setter.Value>
                            </Setter>

                            <Setter TargetName="PART_Track" Property="Orientation" Value="Vertical"/>

                            <Setter Property="Command" Value="ScrollBar.LineLeftCommand" TargetName="DecreaseRepeat"/>
                            <Setter Property="Command" Value="ScrollBar.LineRightCommand" TargetName="IncreaseRepeat"/>
                            <Setter Property="Command" Value="ScrollBar.PageLeftCommand" TargetName="PageDown"/>
                            <Setter Property="Command" Value="ScrollBar.PageRightCommand" TargetName="PageUp"/>
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>-->

    <!-- WPG ScrollViewer Style  -->
    <!--<Style TargetType="{x:Type ScrollViewer}" BasedOn="{x:Null}">
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type ScrollViewer}">
                    <Grid Background="{TemplateBinding Background}">
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="*"/>
                            <ColumnDefinition Width="Auto"/>
                        </Grid.ColumnDefinitions>
                        <Grid.RowDefinitions>
                            <RowDefinition Height="*"/>
                            <RowDefinition Height="Auto"/>
                        </Grid.RowDefinitions>
                        <ScrollContentPresenter Grid.Column="0" Grid.Row="0" Margin="{TemplateBinding Padding}" Content="{TemplateBinding Content}" ContentTemplate="{TemplateBinding ContentTemplate}" CanContentScroll="{TemplateBinding CanContentScroll}"/>

            
                        <ScrollBar Visibility="{TemplateBinding ComputedHorizontalScrollBarVisibility}" Grid.Column="0" Grid.Row="1" x:Name="PART_HorizontalScrollBar" Style="{DynamicResource {x:Type ScrollBar}}" Orientation="Horizontal" Value="{Binding Path=HorizontalOffset, Mode=OneWay, RelativeSource={RelativeSource TemplatedParent}}" ViewportSize="{TemplateBinding ViewportWidth}" Minimum="0" Maximum="{TemplateBinding ScrollableWidth}" AutomationProperties.AutomationId="HorizontalScrollBar"/>
                        <ScrollBar Visibility="{TemplateBinding ComputedVerticalScrollBarVisibility}" Grid.Column="1" Grid.Row="0" x:Name="PART_VerticalScrollBar" Style="{DynamicResource {x:Type ScrollBar}}" Orientation="Vertical" Value="{Binding Path=VerticalOffset, Mode=OneWay, RelativeSource={RelativeSource TemplatedParent}}" ViewportSize="{TemplateBinding ViewportHeight}" Minimum="0" Maximum="{TemplateBinding ScrollableHeight}" AutomationProperties.AutomationId="VerticalScrollBar"/>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>-->

    <!-- WPG SearchListBox Style -->
    <Style x:Key="SearchListBox" TargetType="{x:Type ListBox}">
        <Setter Property="Tag" Value="Search..." />
        <Setter Property="Background" Value="{DynamicResource {x:Static SystemColors.WindowBrushKey}}"/>
        <Setter Property="BorderBrush" Value="{StaticResource ListBorder}"/>
        <Setter Property="BorderThickness" Value="1"/>
        <Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}"/>
        <Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Auto"/>
        <Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Auto"/>
        <Setter Property="ScrollViewer.CanContentScroll" Value="true"/>
        <Setter Property="VerticalContentAlignment" Value="Center"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type ListBox}">

                    <Border x:Name="Bd" SnapsToDevicePixels="true" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Padding="1">

                        <DockPanel LastChildFill="True">
                            <Border DockPanel.Dock="Top" Height="30" CornerRadius="5,5,0,0" Background="{DynamicResource HeaderBackgroundBrush}">
                                <DockPanel LastChildFill="True">
                                    <Border DockPanel.Dock="Right" TextBlock.FontSize="10" Margin="4,4,8,4" CornerRadius="4" Padding="4" Background="#FFB1B1B1" Width="150">
                                        <DockPanel LastChildFill="True">
                                            <Canvas DockPanel.Dock="Right" VerticalAlignment="Center" HorizontalAlignment="Center" Width="22" Height="22">
                                                <Path Width="18.053" Height="18.328" Stretch="Fill" Data="M14.247,0.5 C18.112994,0.5 21.247,3.6340067 21.247,7.5 21.247,11.365993 18.112994,14.5 14.247,14.5 12.775757,14.5 11.410525,14.046114 10.356974,13.164231 L2.467133,21.054071 C2.467133,21.054071 1.9140539,21.577999 1.4999938,21.577999 0.94771242,21.577999 0.5,21.130287 0.5,20.578007 0.5,20.163946 1.0529284,19.639868 1.0529284,19.639868 L8.8727176,11.820078 C7.8251028,10.685783 7.2470002,9.1604033 7.2470002,7.5 7.2470002,3.6340067 10.381007,0.5 14.247,0.5 z" Canvas.Left="2.934" Canvas.Top="1.897">
                                                    <Path.Fill>
                                                        <LinearGradientBrush EndPoint="0.879,0.143" StartPoint="0.087,0.909">
                                                            <GradientStop Color="#FF285D68" Offset="0"/>
                                                            <GradientStop Color="#FFE8EEF0" Offset="1"/>
                                                            <GradientStop Color="#FF59A8BA" Offset="0.269"/>
                                                        </LinearGradientBrush>
                                                    </Path.Fill>
                                                    <Path.Stroke>
                                                        <LinearGradientBrush EndPoint="0.849,0.142" StartPoint="0.151,0.858">
                                                            <GradientStop Color="#FF1E605A" Offset="0"/>
                                                            <GradientStop Color="#FF6CE4D8" Offset="1"/>
                                                        </LinearGradientBrush>
                                                    </Path.Stroke>
                                                </Path>
                                            </Canvas>
                                            <TextBox x:Name="searchText" Style="{x:Null}" BorderThickness="0" Background="Transparent" TextAlignment="Left" BorderBrush="{x:Null}" />
                                        </DockPanel>
                                    </Border>
                                    <TextBlock Text="WPG Inventory" FontSize="16" Foreground="{DynamicResource DefaultForegroundBrush}" Margin="8" HorizontalAlignment="Left" VerticalAlignment="Center" />
                                </DockPanel>
                            </Border>

                            <ScrollViewer Padding="{TemplateBinding Padding}" Focusable="false">
                                <ItemsPresenter SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
                            </ScrollViewer>

                        </DockPanel>
                    </Border>


                    <ControlTemplate.Triggers>
                        <Trigger Property="IsEnabled" Value="false">
                            <Setter Property="Background" TargetName="Bd" Value="{DynamicResource {x:Static SystemColors.ControlBrushKey}}"/>
                        </Trigger>
                        <Trigger Property="IsGrouping" Value="true">
                            <Setter Property="ScrollViewer.CanContentScroll" Value="false"/>
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

</ResourceDictionary>
